import { ApiProperty } from '@nestjs/swagger';
import { IsNotEmpty } from 'class-validator';

export class errorDto {
  @ApiProperty({ example: '状态码' })
  @IsNotEmpty()
  statusCode: number;
  @ApiProperty({ example: '错误类型', required: false })
  @IsNotEmpty()
  error?: string;
  @ApiProperty({ example: '错误消息' })
  @IsNotEmpty()
  message: string;
}
